alert(789);
alert(123);
alert(456);
console.log(1212);
console.log(1111);
(function (window, doc) {
    function Dialog () {
        this.log();
    }
    Dialog.prototype = {
        constructor: Dialog,
        log: function (value) {
            console.log(value);
        }
    };
    window.dialog = Dialog;
})(window, document, undefined);
